package com.hyl.monsterInEachCave;

import com.hyl.creature.Monster;
import com.hyl.creature.MonsterMonkey;

import java.lang.ref.PhantomReference;
import java.util.ArrayList;

/**
 * @description:
 * @author: molar
 * @date: Created in 2020/6/14 17:02
 * @version:
 * @modified By:
 */
public class EntranceMonsterSet {
    private ArrayList<Monster> entranceMonsters = new ArrayList<>();

    public Monster getEntranceMonster(String id){
        Monster entranceMonster = null;
        for (Monster item:entranceMonsters){
            if (id.equals(item.getId()));
            {
                entranceMonster = item;
                break;
            }
        }
        return entranceMonster;
    }

    public EntranceMonsterSet() {
    }

    public EntranceMonsterSet(ArrayList<Monster> entranceMonsters) {
        entranceMonsters = entranceMonsters;
    }

    public ArrayList<Monster> getEntranceMonsters() {
        return entranceMonsters;
    }

    public void setEntranceMonsters(ArrayList<Monster> entranceMonsters) {
        entranceMonsters = entranceMonsters;
    }
}
